package com.server.servlet.product;

import com.bean.Message;

public class RemoveProductServlet extends ProductServletImpl {

	@Override
	protected void success(Message msg) {
		msg.setProduct(resultProduct);
		super.success(msg);
	}

	@Override
	protected boolean isSuccess() {
		return requestProduct != resultProduct;
	}

	@Override
	protected void initData(Message msg) {
		requestProduct = msg.getProduct();
		resultProduct = service.updataQuantity(1, requestProduct);
	}
}
